<template>
	<view class="index_shell">
		<!-- <headnav></headnav> -->
		<index v-if="pageindex == 0"></index>
		<next  v-if="pageindex == 1"></next>
		<last  v-if="pageindex == 2"></last>
		<u-tabbar
			:value="pageindex"
			@change="change1"
			:fixed="true"
			:placeholder="true"
		    :safeAreaInsetBottom="true"
			:zIndex="99"
		>
			<u-tabbar-item text="消息" icon="home" @click="click1" ></u-tabbar-item>
			<u-tabbar-item text="联系人" icon="play-right" @click="click1" ></u-tabbar-item>
			<u-tabbar-item text="我的" icon="account" @click="click1" ></u-tabbar-item>
		</u-tabbar>
	</view>
</template>

<script>
	import headnav from '../../components/headnav.vue'
	import index from '../../components/home/index.vue'
	import first from '../../components/home/first.vue'
	import next from '../../components/home/next.vue'
	import last from '../../components/home/last.vue'
	export default {
		components:{
			headnav,index,first,next,last
		},
		data() {
			return {
				pageindex: 0,
			}
		},
		onLoad() {
			
		},
		methods: {
			 click1(e) {
			 	console.log('click1', e);
				this.pageindex = e
			 },
			 change1(e) {
			 	console.log('click1', e);
			 },
		}
	}
</script>

<style lang="scss" scoped>
.index_shell{
	width: 100vw;
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	// overflow: hidden;
}
</style>
